import java.util.LinkedList;
import java.util.Queue;

public class test {
    /*public static void main(String[] args) {
        MyQueue myQueue=new MyQueue();
        myQueue.offer(3);
        myQueue.offer(5);
        myQueue.offer(6);
        myQueue.offer(7);
        System.out.println(myQueue.poll());
        System.out.println(myQueue.poll());
        System.out.println(myQueue.poll());
        System.out.println(myQueue.poll());*/
    public static void main(String[] args) {
        Queue<Integer> queue=new LinkedList<>();
        queue.offer(2);
        queue.offer(3);
        queue.offer(4);
        queue.offer(5);
        System.out.println(queue.peek());
        System.out.println(queue.poll());
        System.out.println(queue.poll());
        System.out.println(queue.poll());
        System.out.println(queue.poll());
        System.out.println(queue.poll());
    }
}
